<!DOCTYPE html>
<html>

	<head>
		<meta charset="utf-8">
		<title>文章列表--layui后台管理模板 2.0</title>
		<meta name="renderer" content="webkit">
		<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
		<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
		<meta name="apple-mobile-web-app-status-bar-style" content="black">
		<meta name="apple-mobile-web-app-capable" content="yes">
		<meta name="format-detection" content="telephone=no">
		<link rel="stylesheet" href="../../layui/css/layui.css" media="all" />
		<link rel="stylesheet" href="../../css/public.css" media="all" />
	</head>
	<body class="childrenBody">
		<blockquote class="layui-elem-quote">
			所在地勾选项为制定购买人群地区，全部勾选则默认购买人群地区不限制，请根据产品真实购买人群的实际情况进行设置。
		</blockquote>
		<form class="layui-form">
			<input id="user_name" type="hidden" name="user_name" />
			<div class="layui-form-item layui-row layui-col-xs12">
				<label class="layui-form-label">直辖市：</label>
				<div class="layui-input-block zhixiashi">
					<input type="checkbox" name="beijing" value="北京市" title="北京" lay-skin="primary" checked>
					<input type="checkbox" name="shanghai" value="上海市" title="上海" lay-skin="primary" checked>
					<input type="checkbox" name="tianjin" value="天津市" title="天津" lay-skin="primary" checked>
					<input type="checkbox" name="chongqing" value="重庆市" title="重庆" lay-skin="primary" checked>
				</div>
			</div>
			<div class="layui-form-item layui-row layui-col-xs12">
				<label class="layui-form-label">港澳台：</label>
				<div class="layui-input-block gangaotai">
					<input type="checkbox" name="xianggang" value="香港特别行政区" title="香港" lay-skin="primary" checked>
					<input type="checkbox" name="aomen" value="澳门特别行政区" title="澳门" lay-skin="primary" checked>
					<input type="checkbox" name="taiwan" value="台湾省" title="台湾" lay-skin="primary" checked>
				</div>
			</div>
			<div class="layui-form-item layui-row layui-col-xs12">
				<label class="layui-form-label">华北地区：</label>
				<div class="layui-input-block huabeidiqu">
					<input type="checkbox" name="hebei" value="河北省" title="河北" lay-skin="primary" checked>
					<input type="checkbox" name="shanxi" value="山西省" title="山西" lay-skin="primary" checked>
					<input type="checkbox" name="neimenggu" value="内蒙古自治区" title="内蒙古" lay-skin="primary" checked>
					
				</div>
			</div>
			<div class="layui-form-item layui-row layui-col-xs12">
				<label class="layui-form-label">东北地区：</label>
				<div class="layui-input-block dongbeidiqu">
					<input type="checkbox" name="liaoning" value="辽宁省" title="辽宁" lay-skin="primary" checked>
					<input type="checkbox" name="jilin" value="吉林省" title="吉林" lay-skin="primary" checked>
					<input type="checkbox" name="heilongjiang" value="黑龙江省" title="黑龙江" lay-skin="primary" checked>
					
				</div>
			</div>
			<div class="layui-form-item layui-row layui-col-xs12">
				<label class="layui-form-label">华东地区：</label>
				<div class="layui-input-block huadongdiqu">
					<input type="checkbox" name="jiangsu" value="江苏省" title="江苏" lay-skin="primary" checked>
					<input type="checkbox" name="zhejiang" value="浙江省" title="浙江" lay-skin="primary" checked>
					<input type="checkbox" name="anhui" value="安徽省" title="安徽" lay-skin="primary" checked>
					<input type="checkbox" name="fujian" value="福建省" title="福建" lay-skin="primary" checked>
					<input type="checkbox" name="jiangxi" value="江西省" title="江西" lay-skin="primary" checked>
					<input type="checkbox" name="shanxi" value="山东省" title="山东" lay-skin="primary" checked>
					
				</div>
			</div>
			<div class="layui-form-item layui-row layui-col-xs12">
				<label class="layui-form-label">中南地区：</label>
				<div class="layui-input-block zhongnandiqu">
					<input type="checkbox" name="henan" value="河南省" title="河南" lay-skin="primary" checked>
					<input type="checkbox" name="hubei" value="湖北省" title="湖北" lay-skin="primary" checked>
					<input type="checkbox" name="hunan" value="湖南省" title="湖南" lay-skin="primary" checked>
					<input type="checkbox" name="guangdong" value="广东省" title="广东" lay-skin="primary" checked>
					<input type="checkbox" name="guangxi" value="广西壮族自治区" title="广西" lay-skin="primary" checked>
					<input type="checkbox" name="hainan" value="海南省" title="海南" lay-skin="primary" checked>
					
				</div>
			</div>
			<div class="layui-form-item layui-row layui-col-xs12">
				<label class="layui-form-label">西南地区：</label>
				<div class="layui-input-block xinandiqu">
					<input type="checkbox" name="sichuan" value="四川省" title="四川" lay-skin="primary" checked>
					<input type="checkbox" name="guizhou" value="贵州省" title="贵州" lay-skin="primary" checked>
					<input type="checkbox" name="yunnan" value="云南省" title="云南" lay-skin="primary" checked>
					<input type="checkbox" name="xizang" value="西藏自治区" title="西藏" lay-skin="primary" checked>
				</div>
			</div>
			<div class="layui-form-item layui-row layui-col-xs12">
				<label class="layui-form-label">西北地区：</label>
				<div class="layui-input-block xibeidiqu">
					<input type="checkbox" name="shanxi" value="陕西省" title="陕西" lay-skin="primary" checked>
					<input type="checkbox" name="gansu" value="甘肃省" title="甘肃" lay-skin="primary" checked>
					<input type="checkbox" name="qinghai" value="青海省" title="青海" lay-skin="primary" checked>
					<input type="checkbox" name="ningxia" value="宁夏回族自治区" title="宁夏" lay-skin="primary" checked>
					<input type="checkbox" name="xinjiang" value="新疆维吾尔自治区" title="新疆" lay-skin="primary" checked>
					
				</div>
			</div>
			
			
			<div class="layui-form-item layui-row layui-col-xs12">
				<div class="layui-input-block">
					<button id="addcount" class="layui-btn layui-btn-sm" lay-submit="" lay-filter="addcount">立即添加</button>
					<button type="reset" class="layui-btn layui-btn-sm layui-btn-primary">取消</button>
				</div>
			</div>
		</form>
		<script type="text/javascript" src="../../layui/layui.js"></script>
		<script src="../../js/jquery.min.js" type="text/javascript" charset="utf-8"></script>
		<script src="diquxianzhi1.js"></script>
		<script type="text/javascript">
			layui.use(['form', 'layer', 'laydate', 'table', 'laytpl'], function() {
				var form = layui.form,
					layer = parent.layer === undefined ? layui.layer : top.layer,
					$ = layui.jquery,
					laydate = layui.laydate,
					laytpl = layui.laytpl,
					table = layui.table,
					laypage = layui.laypage;
					//$("#shili").show();
					$("#user_name").val(localStorage.login_name);
				
				form.on("submit(addcount)",function(data){
			        //弹出loading
			        //alert($("#file").val());
			        var index = top.layer.msg('数据提交中，请稍候',{icon: 16,time:false,shade:0.8});
			        var action 	= data.form.action;//表单提交URL地址
			        
			        var arr_box = [];
				    $('input[type=checkbox]:checked').each(function() {
				      arr_box.push($(this).val());
				    });
				    console.log(JSON.stringify(data.field));
			        
			        
			        //var da		= data.field;
			        //console.log(data.field);
			        /*$.post("http://127.0.0.1:88/index.php/diqu/diqu",arr_box,function(obj){
			        	if(obj.code==500){
			        		setTimeout(function(){
				        		layer.msg(obj.msg);
				        	},2000);
			        	}else{
				        	setTimeout(function(){
				        		layer.msg(obj.msg);
				        		top.layer.close(index);
						        //top.layer.msg("商铺添加成功！");
						        layer.closeAll("iframe");
						        //刷新父页面
						        parent.location.reload();
				        		
				        	},2000);
			        	}
			        });*/
			      /*  setTimeout(function(){
			            top.layer.close(index);
			            //top.layer.msg("商铺添加成功！");
			            layer.closeAll("iframe");
			            //刷新父页面
			            parent.location.reload();
			        },2000);*/
			        return false;
			    })
				
			})
			
		</script>
	</body>

</html>